﻿@model List<GameMall_Front.ViewModels.Customer.ViewModelShoppingCars>
@{
    Layout = "~/Views/Shared/_Layout.cshtml";
}
@section css{
    @Styles.Render("~/Css/shopping_car.css")
}
@section scripts{
    @Scripts.Render("~/Js/checked.js")
}
@*<script src="~/Js/jquery-1.9.1.js"></script>
<script src="~/Js/checked.js"></script>*@
<div class="container">
    <div class="position-block">
        <div class="position">
            我的位置>购物车
        </div>
    </div>
    @if (Model.Count == 0)
    {
       <div>购物车空空如也，快去添加吧!</div>
    }
    else
    {
            <div class="shopping_car">
                <table>
                    <thead>
                        <tr>
                            <th>
                                <input type="checkbox" name="chooseAll" />全选
                            </th>
                            <th>游戏名称</th>
                            <th>游戏版本</th>
                            <th>版本图片</th>
                            <th>单价</th>
                            <th>数量</th>
                            <th>小计</th>
                            <th>操作</th>
                        </tr>
                    </thead>
                    <tbody id="ItemShoppingCar">
                        @Html.Partial("ItemShoppingCar", Model)
                    </tbody>
                    <tfoot>
                        <tr>
                            <td>
                                <input type="checkbox" name="chooseAll" />全选
                            </td>
                            <td>
                                <button id="delete_choosed">删除</button>
                            </td>
                            <td colspan="6">
                                <span>已选商品2件</span>
                                <span>合计：￥234</span>
                                <form id="shoppingCarForm" action="/FrontOrder/PlaceOrderByShoppingCar">
                                    <input type="hidden" name="shoppingCarIdJsonStr" id="shoppingCarId"/>
                                    <input type="hidden" name="goodsNumberJsonStr" id="goodsNumber"/>
                                    <button type="button" id="Settlement_button">结算</button>
                                </form>
                            </td>
                        </tr>
                    </tfoot>
                </table>
            </div>   
    }
</div>

